package com.demo.service.impl;

import com.demo.dao.ManagerDao;
import com.demo.dao.PermDao;
import com.demo.pojo.Manager;
import com.demo.pojo.Perm;
import com.demo.service.ManagerService;
import com.demo.service.PermService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

@Service
public class PermServiceImpl implements PermService {
    @Autowired
    PermDao permDao;

    public void setPermDao(PermDao permDao) {
        this.permDao = permDao;
    }

    @Override
    public Perm findOne(int id) {
        return permDao.findOne(id);
    }

    @Override
    public List<Perm> findOnePage() {
        return permDao.findOnePage();
    }

    @Override
    public int deleteOne(int id) {
        return permDao.deleteOne(id);
    }

    @Override
    public int addOne(Map<String, Object> map) {
        return permDao.addOne(map);
    }

    @Override
    public int changeName(Map<String, Object> map) {
        return permDao.changeName(map);
    }


}
